/**
 * 
 */
package com.hand.cloud.b2b.daos.impl;

import de.hybris.platform.ordersplitting.model.StockLevelModel;
import de.hybris.platform.servicelayer.ServicelayerTransactionalTest;
import de.hybris.platform.servicelayer.model.ModelService;

import javax.annotation.Resource;

import org.junit.Test;

import com.hand.cloud.b2b.daos.StockLevelDAO;
import com.hand.cloud.b2b.model.EPStockLevelModel;


/**
 * @author ruifengho
 * @time 2014-8-18 下午2:25:27
 * 
 */
public class DefaultStockLevelDAOTest extends ServicelayerTransactionalTest
{

	@Resource
	private StockLevelDAO stockLevelDAO;


	@Test
	public void test()
	{
		EPStockLevelModel stockLevel = new EPStockLevelModel();
		stockLevel.setAvailable(Integer.valueOf(0));
		stockLevel.setMaxPreOrder(Integer.valueOf(0));
		stockLevel.setMaxStockLevelHistoryCount(Integer.valueOf(-1));
		stockLevel.setOverSelling(Integer.valueOf(0));
		stockLevel.setPreOrder(Integer.valueOf(0));
		stockLevel.setProductCode("hand");
		stockLevel.setReserved(Integer.valueOf(0));
		StockLevelModel stockLevelModel = stockLevelDAO.createStockLevel(stockLevel);
		System.out.println(stockLevelModel.getPk());
	}

}
